package net.cloudcodex.shared;

/**
 * Errors codes.
 * 
 * @author Thomas
 */
public interface Errors {

	/**
	 * The user is not registered
	 */
	String NOT_REGISTERED = "notregistered";

	/**
	 * Generic, a parameter is invalid
	 */
	String ARGUMENT = "argument";

	/**
	 * Generic, a required parameter has not been provided.
	 */
	String REQUIRED = ARGUMENT + ".required";
	
	/**
	 * Generic, an entity has not been found.
	 */
	String NOT_FOUND = "notfound";

	/**
	 * The campaign has not been found.
	 */
	String NOT_FOUND_CAMPAIGN = NOT_FOUND + ".campaign";

	/**
	 * The user has not been found.
	 */
	String NOT_FOUND_USER = NOT_FOUND + ".user";

	/**
	 * The character has not been found.
	 */
	String NOT_FOUND_CHARACTER = NOT_FOUND + ".character";

	/**
	 * The scene has not been found.
	 */
	String NOT_FOUND_SCENE = NOT_FOUND + ".scene";

	/**
	 * The message has not been found.
	 */
	String NOT_FOUND_MESSAGE = NOT_FOUND + ".message";

	/**
	 * The message note has not been found.
	 */
	String NOT_FOUND_MESSAGE_NOTE = NOT_FOUND + ".message.note";

	/**
	 * Generic, the user has tried an operation as another.
	 */
	String USER_USURPATION = "user.usurpation";
	
	/**
	 * The user tried an operation as a NPC.
	 */
	String USER_USURPATION_NPC = USER_USURPATION + ".npc";

	/**
	 * The user tried an operation as another PC.
	 */
	String USER_USURPATION_PC = USER_USURPATION + ".pc";

	/**
	 * The user tried an operation as the GM.
	 */
	String USER_USURPATION_GM = USER_USURPATION + ".gm";

	/**
	 * Generic, an operation is not possible
	 */
	String IMPOSSIBLE = "impossible";

	/**
	 * The user tried an impossible operation on a profile.
	 */
	String IMPOSSIBLE_PROFILE = IMPOSSIBLE + ".profile";

	/**
	 * The user tried an impossible operation on a locked entity.
	 */
	String IMPOSSIBLE_LOCKED = IMPOSSIBLE + ".locked";

	/**
	 * The user tried an impossible operation on a closed entity.
	 */
	String IMPOSSIBLE_CLOSED = IMPOSSIBLE + ".closed";

	/**
	 * The user tried an impossible operation on a deleted entity.
	 */
	String IMPOSSIBLE_DELETED = IMPOSSIBLE + ".deleted";

	/**
	 * The user tried an impossible operation on a paused entity.
	 */
	String IMPOSSIBLE_PAUSED = IMPOSSIBLE + ".paused";

	/**
	 * The user tried an impossible operation on a dead entity.
	 */
	String IMPOSSIBLE_DEAD = IMPOSSIBLE + ".dead";

	/**
	 * The GM tried to create a scene with only NPCs.
	 */
	String IMPOSSIBLE_ONLY_NPCS = IMPOSSIBLE + ".onlynpcs";
	
	/**
	 * The GM tried to create scenes but all PCs are nor dispathched
	 */
	String IMPOSSIBLE_PC_NOT_DISPATCHED = IMPOSSIBLE + ".pcnotdispatched";
	
	/**
	 * You're trying to have a playable character in two scenes at the scene time.
	 */
	String IMPOSSIBLE_UBIQUITY = IMPOSSIBLE + ".ubiquity";

	/**
	 * You're trying to create something which already exists.
	 */
	String IMPOSSIBLE_EXISTS = IMPOSSIBLE + ".exists";

	/**
	 * You're trying to do something for yourself where only external users
	 * can be used (ie : invite to campaign)
	 */
	String IMPOSSIBLE_YOURSELF = IMPOSSIBLE + ".yourself";
	
	/**
	 * The client is not up-to-date, it musts refresh before retrying the
	 * operation. ie : posting message on a obsolete scene.
	 */
	String OUTOFDATE = "out-of-date";

}
